const express = require('express');
const app = express();
const config=require('./config');
const {Ajax, enu} = require("./utils/Ajax");
const logging = require("./utils/log");
app.use(express.json());
app.use(require('./setting/interceptor'));
app.use(require('./controller/Captcha').router);
app.use(require('./controller/UserLogin'));
app.use(require('./controller/SystemStatus'));
app.use(require('./controller/InterceptStatus'));


app.get('/', (req, res) => {
    res.send(Ajax(enu().code.service.success,`欢迎使用${config().ProjectName},版本${config().version}`))
})

app.listen(config().port,()=>{
    logging('warn','jenkins server start '+config().port)
})